package c.a.a.z.b;

import android.graphics.Path;
import android.graphics.Path.FillType;
import c.a.a.b0.k.o;
import c.a.a.l;
import c.a.a.z.c.a;
import c.a.a.z.c.a.b;
import java.util.List;

/* compiled from: ShapeContent */
public class q implements m, b {
    public final Path a = new Path();
    public final boolean b;
    public final l c;
    public final a<?, Path> d;
    public boolean e;
    public b f = new b();

    public q(l lVar, c.a.a.b0.l.b bVar, o oVar) {
        this.b = oVar.d;
        this.c = lVar;
        a a = oVar.c.a();
        this.d = a;
        bVar.e(a);
        a.a.add(this);
    }

    public void c() {
        this.e = false;
        this.c.invalidateSelf();
    }

    public void d(List<c> list, List<c> list2) {
        for (int i = 0; i < list.size(); i++) {
            c cVar = (c) list.get(i);
            if (cVar instanceof s) {
                s sVar = (s) cVar;
                if (sVar.c == c.a.a.b0.k.q.a.SIMULTANEOUSLY) {
                    this.f.a.add(sVar);
                    sVar.b.add(this);
                }
            }
        }
    }

    public Path h() {
        if (this.e) {
            return this.a;
        }
        this.a.reset();
        if (this.b) {
            this.e = true;
            return this.a;
        }
        this.a.set((Path) this.d.e());
        this.a.setFillType(FillType.EVEN_ODD);
        this.f.a(this.a);
        this.e = true;
        return this.a;
    }
}
